﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ServiceModel;
using TestConsole.CF_DAL_WS;

namespace TestConsole
{
    class Program
    {
        static void Main(string[] args)
        {
            var svc = new ChannelFactory<ICF_DAL_Service>("BasicHttpBinding_ICF_DAL_Service").CreateChannel();
            try
            {
                var data = svc.Restaurant_SelectByIDDistrictAndIDFoodType("1", "1");
                foreach (var item in data)
                {
                    Console.WriteLine(item.Name);
                }
            }
            catch (Exception ex)
            {
                if (ex.InnerException != null)
                {
                    Console.WriteLine(ex.InnerException.Message);
                }
                else
                {
                    Console.WriteLine(ex.Message);
                }
            }           
        }
    }
}
